#ifndef SELECTOR_MANAGER_OSG
#define SELECTOR_MANAGER_OSG 1

#include<iostream>
#include<vector>

#include <osg/Node>
#include <osg/StateSet>
#include <osgFX/Outline>

class SelectorManagerOsg : public osg::Node
{
	
public:
    ~SelectorManagerOsg();
    static SelectorManagerOsg* instance();

	void addSelectedNode(osg::ref_ptr<osg::Node> node_ptr);
	void addSingleSelectedNode(osg::ref_ptr<osg::Node> node_ptr);
	int getSelectedNodeSize();
	osg::ref_ptr<osg::Node> getSelectedNode(int index);
    void cancelSelectedNode();
    //osg::ref_ptr<osgFX::Outline> getOutlineNode();


protected:
	void handleSelectedNode();

private:
    SelectorManagerOsg();
    static SelectorManagerOsg* _instance;


    //std::vector<osg::ref_ptr<osg::Node>> _selected_node_vector;
	
    //std::vector<osg::ref_ptr<osg::StateSet>> _selected_node_stateset_vector;

    //osg::ref_ptr<osgFX::Outline> m_outLineNode;

    std::vector<osg::ref_ptr<osgFX::Outline>> m_outLineNodeVector;
    //osg::ref_ptr<osg::Group> m_selectedNode;
    std::vector<osg::ref_ptr<osg::Node>> m_selectedNode;
    bool m_isAdding;
    bool m_isCanceling;
};

#endif //!SELECTOR_MANAGER_OSG
